﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections.Specialized;
using System.Configuration;

namespace LapvBussiness
{
    public class ConfigLapv
    {
        private static ConfigLapv _instance = null;
        public static ConfigLapv Instance
        {
            get
            {
                if (_instance == null)
                {
                    _instance = new ConfigLapv();

                }
                return _instance;
            }
        }

        private string getListConfigEdu(string configName)
        {
            string reval = "";

            if (!string.IsNullOrEmpty(configName))
            {
                //var obj = Provider.GetConfigEdu(configName);
                //if (obj != null)
                //{
                //    reval = obj.value;
                //}

            }
            return reval;
        }
        protected ConfigLapv()
        {

            _DomainWeb = getAppStr("DomainWeb");
            _DomainStyle = getAppStr("DomainStyle");
            _DomainAdmin = getAppStr("DomainAdmin");

        }
        private string getAppStr(string Name)
        {
            NameValueCollection configSettings = ConfigurationManager.GetSection("appSettings") as NameValueCollection;
            if (configSettings != null)
            {
                string configValue = configSettings[Name] as string;
                if (configValue != null)
                {
                    return configValue;
                }
            }
            return string.Empty;
        }
        #region Domain
        private string _DomainWeb;
        public string DomainWeb
        {
            get
            {
                return _instance._DomainWeb;
            }
        }

        private string _DomainAdmin;
        public string DomainAdmin
        {
            get
            {
                return _instance._DomainAdmin;
            }
        } 
       

        private string _DomainStyle;
        public string DomainStyle
        {
            get
            {
                return _instance._DomainStyle;
            }
        }

     

        #endregion


    }
}
